package org.itboys.core.entity.mongo;

import lombok.Data;
import org.itboys.mongodb.entity.BaseMongoEntity;
import org.mongodb.morphia.annotations.Entity;

/**
 * 作者：zzq
 * 时间：2018/12/5
 * 描述：托盘投放记录
 */
@Data
@Entity(value = "SundayTrayApply", noClassnameStored = true)
public class SundayTrayApply extends BaseMongoEntity {
    private Long memberId;//供应商id
    private Long modelId;//模板id
    private Long storeId;//仓库id
    private Long  num;//投放数量
    private Integer status;//1，申请中 2，已通过 3，已驳回
    private String zipPath;//图片压缩文件路径

    public SundayTrayApply() {
    }

    public SundayTrayApply(Long memberId, Long modelId, Long storeId, Long num, Integer status) {
        this.memberId = memberId;
        this.modelId = modelId;
        this.storeId = storeId;
        this.num = num;
        this.status = status;
    }


    public String getStatusStr() {
        String statusStr="";
        if(status==null)return statusStr;

        switch (status) {
            case 1:
                statusStr="审核中";
                break;
            case 2:
                statusStr="已通过";
                break;
            case 3:
                statusStr="已驳回";
                break;
            default:
                break;
        }
        return statusStr;
    }
}
